<div class="widgets">
  <div class="row">
    <div class="col-xs-12">
      <ba-card baCardClass="with-scroll">
        <div class="section">
          <form (ngSubmit)="search()" class="form-horizontal search-form">
            <div class="form-group row">
              <div class="col-sm-5" id="publishTimeCol">
                <label id="publishTimeLabel" for="startdate" class="col-sm-5 control-label">发布时间</label>
                <div class="col-sm-7">
                  <date-range-picker (onSelected)="updateDateRange($event)"></date-range-picker>
                </div>
              </div>
              <div class="col-sm-5">
                <label for="title" class="control-label col-sm-5">公告标题</label>
                <div class="col-sm-7">
                  <input type="text" id="title" name="title" [(ngModel)]="searchForm.title"
                         class="form-control inline-form-control">
                </div>
              </div>
              <div class="col-sm-2">
                <button type="submit" class="btn btn-primary pull-left"><i class="fa fa-search" aria-hidden="true"></i>
                  查询
                </button>
              </div>
            </div>
          </form>
        </div>
        <div class="section btn-section btn-toolbar">
          <a routerLink="add" class="btn btn-success btn-pass">添加</a>
          <a role="button" class="btn btn-danger btn-reject" [ngClass]="{'disabled': disableDeleteBtn}"
             (click)="deleteNotification()">删除</a>
          <span *ngIf="errorShow">网络异常，请重新登录</span>
        </div>
        <div class="section">
          <data-tables [searchParams]="searchForm" [config]="dataTablesConfig"
                       (onSelect)="tableRowSelect($event)" (onError)="handleError($event)"></data-tables>
        </div>
      </ba-card>
    </div>
  </div>
</div>
